<?php

use Illuminate\Database\Seeder;

class AdminPermissionsTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        DB::table('admin_permissions')->insert([
            [
                "id" => 1,
                "name" => "Auth management",
                "slug" => "auth-management",
                "http_method" => "",
                "http_path" => json_encode([
                    ""
                ], true),
                "order" => 1,
                "parent_id" => 0
            ],
            [
                "id" => 2,
                "name" => "Users",
                "slug" => "users",
                "http_method" => "",
                "http_path" => json_encode([
                    "/auth/users*"
                ], true),
                "order" => 2,
                "parent_id" => 1
            ],
            [
                "id" => 3,
                "name" => "Roles",
                "slug" => "roles",
                "http_method" => "",
                "http_path" => json_encode([
                    "/auth/roles*"
                ], true),
                "order" => 3,
                "parent_id" => 1
            ],
            [
                "id" => 4,
                "name" => "Permissions",
                "slug" => "permissions",
                "http_method" => "",
                "http_path" => json_encode([
                    "/auth/permissions*"
                ], true),
                "order" => 4,
                "parent_id" => 1
            ],
            [
                "id" => 5,
                "name" => "Menu",
                "slug" => "menu",
                "http_method" => "",
                "http_path" => json_encode([
                    "/auth/menu*"
                ], true),
                "order" => 5,
                "parent_id" => 1
            ],
            [
                "id" => 6,
                "name" => "Operation log",
                "slug" => "operation-log",
                "http_method" => "",
                "http_path" => json_encode([
                    "/auth/logs*"
                ], true),
                "order" => 6,
                "parent_id" => 1
            ],
            [
                "id" => 7,
                "name" => "地区管理",
                "slug" => "region-list",
                "http_method" => "",
                "http_path" => json_encode([
                    "/region/*"
                ], true),
                "order" => 7,
                "parent_id" => 0
            ],
            [
                "id" => 8,
                "name" => "模块分类管理",
                "slug" => "cartgory-list",
                "http_method" => "",
                "http_path" => json_encode([
                    "/cartgory/*"
                ], true),
                "order" => 8,
                "parent_id" => 0
            ],
            [
                "id" => 9,
                "name" => "广告位分类管理",
                "slug" => "adv",
                "http_method" => "",
                "http_path" => json_encode([
                    "/adv/*"
                ], true),
                "order" => 9,
                "parent_id" => 0
            ],
            [
                "id" => 10,
                "name" => "市场管理",
                "slug" => "agric-goods",
                "http_method" => "",
                "http_path" => json_encode([
                    "/goods_category*",
                    "/goods_seller*",
                    "/goods*"
                ], true),
                "order" => 10,
                "parent_id" => 0
            ],
            [
                "id" => 11,
                "name" => "服务管理",
                "slug" => "fuwu",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_category/2/manage*",
                    "/service_article/2/manage*"
                ], true),
                "order" => 11,
                "parent_id" => 0
            ],
            [
                "id" => 12,
                "name" => "党务管理",
                "slug" => "dangwu",
                "http_method" => "",
                "http_path" => json_encode([
                    "/political_user*",
                    "/service_category/3/manage*",
                    "/service_article/3/manage*",
                    "/political_mailbox*"
                ], true),
                "order" => 12,
                "parent_id" => 0
            ],
            [
                "id" => 13,
                "name" => "产业管理",
                "slug" => "chanye",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_category/4/manage*",
                    "/service_article/4/manage*"
                ], true),
                "order" => 13,
                "parent_id" => 0
            ],
            [
                "id" => 14,
                "name" => "技术管理",
                "slug" => "jishu",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_article/5/manage*",
                    "/adv_content/1/manage*"
                ], true),
                "order" => 14,
                "parent_id" => 0
            ],
            [
                "id" => 15,
                "name" => "文化管理",
                "slug" => "wenhua",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_category/6/manage*",
                    "/service_article/6/manage*",
                    "/adv_content/2/manage*",
                    "/adv_content/3/manage*"
                ], true),
                "order" => 15,
                "parent_id" => 0
            ],
            [
                "id" => 16,
                "name" => "村务管理",
                "slug" => "cunwu",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_category/7/manage*",
                    "/service_article/7/manage*",
                    "/adv_content/4/manage*",
                    "/farmer_feedbacks*"
                ], true),
                "order" => 16,
                "parent_id" => 0
            ],
            [
                "id" => 17,
                "name" => "政策管理",
                "slug" => "zhengce",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_article/8/manage*",
                    "/adv_content/5/manage*"
                ], true),
                "order" => 17,
                "parent_id" => 0
            ],
            [
                "id" => 18,
                "name" => "兴农管理",
                "slug" => "xingnong",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_category/9/manage*",
                    "/service_article/9/manage*",
                    "/adv_content/6/manage*"
                ], true),
                "order" => 18,
                "parent_id" => 0
            ],
            [
                "id" => 19,
                "name" => "利民管理",
                "slug" => "liming",
                "http_method" => "",
                "http_path" => json_encode([
                    "/service_category/10/manage*",
                    "/service_article/10/manage*",
                    "/adv_content/7/manage*",
                    "/adv_content/8/manage*"
                ], true),
                "order" => 19,
                "parent_id" => 0
            ],
            [
                "id" => 20,
                "name" => "调查问卷管理",
                "slug" => "diaochawenjuan",
                "http_method" => "",
                "http_path" => json_encode([
                    "/paper_library*"
                ], true),
                "order" => 20,
                "parent_id" => 0
            ],
            [
                "id" => 21,
                "name" => "短视频管理",
                "slug" => "duanshiping",
                "http_method" => "",
                "http_path" => json_encode([
                    "/video*"
                ], true),
                "order" => 21,
                "parent_id" => 0
            ]
        ]);
    }
}
